package org.afs.gescol.core.model.data;

import javax.persistence.AttributeOverride;
import javax.persistence.AttributeOverrides;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

import org.scub.foundation.framework.core.model.BaseModel;

/**
 * Model for representing teachers.
 * @author Kobla GBENYO (kobla.gbenyo@gmail.com)
 */
@Entity
@Table(name = "data_teacher")
@AttributeOverrides({@AttributeOverride(name = "id", column = @Column(name = "teacher_id", nullable = false)),
    @AttributeOverride(name = "version", column = @Column(name = "teacher_version", nullable = false, unique = false)),
})
public class Teacher extends BaseModel {

    /** Serial Version UID. */
    private static final long serialVersionUID = 4938451170967140949L;

    @Column(name = "teacher_last_name", nullable = false)
    private String lastName;

    @Column(name = "teacher_first_name")
    private String firstName;

    /**
     * Get the value of lastName.
     * @return the lastName
     */
    public String getLastName() {
        return lastName;
    }

    /**
     * Set the value of lastName.
     * @param lastName the lastName to set
     */
    public void setLastName(String lastName) {
        this.lastName = lastName;
    }

    /**
     * Get the value of firstName.
     * @return the firstName
     */
    public String getFirstName() {
        return firstName;
    }

    /**
     * Set the value of firstName.
     * @param firstName the firstName to set
     */
    public void setFirstName(String firstName) {
        this.firstName = firstName;
    }

    @Override
    public boolean equals(Object other) {
        return equalsUtil(other);
    }

    @Override
    public int hashCode() {
        return super.hashCode();
    }

}
